Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add composables autoimport #4

Merged
merged 1 commit into from
Aug 2, 2023
Merged

Conversation

FRSgit
Copy link
Contributor

@FRSgit FRSgit commented Aug 1, 2023

fix component import typings
update module structure

BREAKING CHANGE: component is now autoimported as due to nuxt addComponent() issue

fix component import typings
update module structure

BREAKING CHANGE: <LazyHydrate> component is now autoimported as <NuxtLazyHydrate> due to nuxt addComponent() issue
@FRSgit
Copy link
Contributor Author

FRSgit commented Aug 1, 2023

This PR fixes module behaviour in newer nuxt versions:
<LazyHydrate> component typings weren't properly read by volar in VSC - component was typed as unknown.

Unfortunately, nuxt addComponent() api fails when trying to register component named Lazy* - component wasn't loading at all in the module playground. To avoid this issue I needed to change component name to NuxtLazyHydrate (this name follows pattern of NuxtLink or `NuxtImg).

Copy link
Owner

@Baroshem Baroshem left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @FRSgit 💚

@Baroshem Baroshem merged commit 062fa68 into Baroshem:main Aug 2, 2023
@FRSgit FRSgit deleted the patch-1 branch August 2, 2023 16:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants